package view.LoginRigister.Conponents;

import view.Interface.button.ClickEventHandler;
import view.Interface.button.CustomButton;

import javax.swing.*;
import java.awt.*;

public class ContainerLoginRigisterButton extends JPanel {
        CustomButton loginButton;
        CustomButton registerButton;
        public ContainerLoginRigisterButton(ClickEventHandler loginhandler, ClickEventHandler rigisterhandler) {
            JPanel buttonPanel = new JPanel(new FlowLayout(FlowLayout.CENTER, 10, 10));
            loginButton = new CustomButton("登录");
            registerButton = new CustomButton("注册");
            loginButton.setOnClickListener(loginhandler);
            registerButton.setOnClickListener(rigisterhandler);

            add(loginButton);
            add(registerButton);
        }

    }